home *** CD-ROM | disk | FTP | other *** search
/ Chip 2000 February / OpenLinux 2.3 CD.iso / live / usr / share / vim / syntax / sather.vim < prev    next >
Encoding:
Text File  |  1999-08-10  |  3.5 KB  |  93 lines

  1. " Vim syntax file
  2. " Language:    Sather/pSather
  3. " Maintainer:    Claudio Fleiner <claudio@fleiner.com>
  4. " URL:        http://www.fleiner.com/vim/syntax/sather.vim
  5. " Last change:    1998 Jan 12
  6.  
  7. " Sather is a OO-language developped at the International Computer Science
  8. " Institute (ICSI) in Berkeley, CA. pSather is a parallel extension to Sather.
  9. " Homepage: http://www.icsi.berkeley.edu/~sather
  10. " Sather files use .sa as suffix
  11.  
  12. " Remove any old syntax stuff hanging around
  13. syn clear
  14.  
  15. " keyword definitions
  16. syn keyword satherExternal       extern
  17. syn keyword satherBranch         break continue
  18. syn keyword satherLabel          when then
  19. syn keyword satherConditional    if else elsif end case typecase assert with
  20. syn match satherConditional      "near$"
  21. syn match satherConditional      "far$"
  22. syn match satherConditional      "near *[^(]"he=e-1
  23. syn match satherConditional      "far *[^(]"he=e-1
  24. syn keyword satherSynchronize    lock guard sync
  25. syn keyword satherRepeat         loop parloop do
  26. syn match satherRepeat           "while!"
  27. syn match satherRepeat           "break!"
  28. syn match satherRepeat           "until!"
  29. syn keyword satherBoolValue      true false
  30. syn keyword satherValue          self here cluster
  31. syn keyword satherOperator       new "== != & ^ | && ||
  32. syn keyword satherOperator       and or not
  33. syn match satherOperator         "[#!]"
  34. syn match satherOperator         ":-"
  35. syn keyword satherType           void attr where
  36. syn match satherType           "near *("he=e-1
  37. syn match satherType           "far *("he=e-1
  38. syn keyword satherStatement      return
  39. syn keyword satherStorageClass   static const
  40. syn keyword satherExceptions     try raise catch
  41. syn keyword satherMethodDecl     is pre post
  42. syn keyword satherClassDecl      abstract value class include
  43. syn keyword satherScopeDecl      public private readonly
  44.  
  45.  
  46. syn match   satherSpecial           contained "\\\d\d\d\|\\."
  47. syn region  satherString            start=+"+  skip=+\\\\\|\\"+  end=+"+  contains=satherSpecial
  48. syn match   satherCharacter         "'[^\\]'"
  49. syn match   satherSpecialCharacter  "'\\.'"
  50. syn match   satherNumber          "-\=\<\d\+L\=\>\|0[xX][0-9a-fA-F]\+\>"
  51. syn match   satherCommentSkip     contained "^\s*\*\($\|\s\+\)"
  52. syn region  satherComment2String  contained start=+"+  skip=+\\\\\|\\"+  end=+$\|"+  contains=satherSpecial
  53. syn match   satherComment         "--.*" contains=satherComment2String,satherCharacter,satherNumber
  54.  
  55.  
  56. syn sync ccomment satherComment
  57.  
  58.  
  59. if !exists("did_sather_syntax_inits")
  60.   let did_sather_syntax_inits = 1
  61.   " The default methods for highlighting.  Can be overridden later
  62.   hi link satherBranch        satherStatement
  63.   hi link satherLabel        satherStatement
  64.   hi link satherConditional    satherStatement
  65.   hi link satherSynchronize    satherStatement
  66.   hi link satherRepeat        satherStatement
  67.   hi link satherExceptions    satherStatement
  68.   hi link satherStorageClass    satherDeclarative
  69.   hi link satherMethodDecl    satherDeclarative
  70.   hi link satherClassDecl    satherDeclarative
  71.   hi link satherScopeDecl    satherDeclarative
  72.   hi link satherBoolValue    satherValue
  73.   hi link satherSpecial        satherValue
  74.   hi link satherString        satherValue
  75.   hi link satherCharacter    satherValue
  76.   hi link satherSpecialCharacter    satherValue
  77.   hi link satherNumber        satherValue
  78.   hi link satherStatement    Statement
  79.   hi link satherOperator    Statement
  80.   hi link satherComment        Comment
  81.   hi link satherType        Type
  82.   hi link satherValue        String
  83.   hi link satherString        String
  84.   hi link satherSpecial        String
  85.   hi link satherCharacter    String
  86.   hi link satherDeclarative    Type
  87.   hi link satherExternal    PreCondit
  88. endif
  89.  
  90. let b:current_syntax = "sather"
  91.  
  92. " vim: ts=8
  93.